#!/usr/bin/env python
# -*- coding: UTF-8 -*-
'''
@Project ：图灵学习 
@File    ：17.二进制文件写入.py
@IDE     ：PyCharm 
@Author  ：ChenLiGao
@Date    ：2024-10-31 09:51
'''
import requests

response = requests.get("https://www.baidu.com/img/PCtm_d9c8750bed0b3c7d089fa7d55720d6cf.png").content

print(response)

with open("baidu.png", mode="wb") as file:
    file.write(response)